package com.financing.platform.service.impl;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.financing.platform.dao.IProductNoticeDao;
import com.financing.platform.dto.ProductNoticeDTO;
import com.financing.platform.service.IProductNoticeService;

@Service(value="productNoticeService")
public class ProductNoticeServiceImpl implements IProductNoticeService{
	
	@Autowired
	IProductNoticeDao productNoticeDao;
	
	public int insertProdcutNotice(Map<String,String> productNotice) throws SQLException{
		return productNoticeDao.insertProdcutNotice(productNotice);
		
	}

	@Override
	public int queryProdcutNotice(String detailUrl) throws SQLException {
		return productNoticeDao.queryProdcutNotice(detailUrl);
	}

	@Override
	public List<String> queryProdcutNoticeUrlList(Integer i) throws SQLException {
		return productNoticeDao.queryProdcutNoticeUrlList(i);
	}

	@Override
	public List<ProductNoticeDTO> queryProdcutNoticeList(ProductNoticeDTO pndto)
			throws SQLException {
		return productNoticeDao.queryProdcutNoticeList(pndto);
	}

	@Override
	public ProductNoticeDTO queryProdcutNoticeDetail(ProductNoticeDTO pndto)
			throws SQLException {
		return productNoticeDao.queryProdcutNoticeDetail(pndto);
	}

	@Override
	public int updateProdcutNotice(ProductNoticeDTO pndto) throws SQLException {
		return productNoticeDao.updateProdcutNotice(pndto);
	}

	@Override
	public int countProdcutNoticeList(ProductNoticeDTO pndto)
			throws SQLException {
		return productNoticeDao.countProdcutNoticeList(pndto);
	}

}
